package com.wuyu.service;

import com.wuyu.base.BaseService;
import com.wuyu.dao.UserMyBaseMapper;
import com.wuyu.domain.User;
import com.wuyu.recDomain.UserRecDomain;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


@Service
public class UserService extends BaseService<User> {

    private static Logger logger = LoggerFactory.getLogger(UserService.class);
    
	@Autowired
	private UserMyBaseMapper UserMapper;

	public List<User> getUser(User User) {
		List<User> Users = UserMapper.queryAll(null);
		return Users;
	}
    
    public User selectUserByCondition(UserRecDomain userRecDomain) {
        
        User user = new User();    
        BeanUtils.copyProperties(userRecDomain , user);
        
        User user1 = (User)UserMapper.selectUserByCondition(user);
        
        return user1;
    }

    public int delete(String ids) {

         return 0;
    } 
}
